package com.sh.suhe.utildemos.book.base;


public abstract class BasePresenter<T extends LoadCallBack> {
//    protected CompositeDisposable mDisposable;
    /* access modifiers changed from: protected */
    public T view;

    public Boolean checkBool(String str) {
        try {
            if (str.equals("1")) {
                return Boolean.valueOf(true);
            }
            return Boolean.valueOf(false);
        } catch (Exception e) {
            e.printStackTrace();
            return Boolean.valueOf(false);
        }
    }

    /* access modifiers changed from: protected */
//    public void addDisposable(Disposable disposable) {
//        if (this.mDisposable == null) {
//            this.mDisposable = new CompositeDisposable();
//        }
//        this.mDisposable.add(disposable);
//    }

    /* access modifiers changed from: protected */
    public void unSubscribe() {
//        if (this.mDisposable != null) {
//            this.mDisposable.dispose();
//        }
    }

    public void onDestroy() {
        this.view = null;
        unSubscribe();
    }
}
